package com.hl.apilibrary;

import com.hl.apilibrary.bean.BaseRespose;
import com.hl.apilibrary.bean.EmotionGroup;
import com.hl.apilibrary.bean.Sticky;
import com.hl.apilibrary.bean.TTF;
import com.hl.apilibrary.bean.TextBubble;
import com.hl.apilibrary.bean.Theme;

import java.util.HashMap;
import java.util.List;

import okhttp3.ResponseBody;
import retrofit2.Call;
import retrofit2.http.GET;
import retrofit2.http.Headers;
import retrofit2.http.POST;
import retrofit2.http.QueryMap;
import retrofit2.http.Streaming;
import retrofit2.http.Url;

public interface ApiService {

    @Streaming //添加这个注解用来下载大文件
    @GET()
    @Headers("Accept-Encoding: identity")
    Call<ResponseBody> download(@Url String fileUrl);

    @Headers("version: 1.0.0")
    @POST("Robot/ttf")
    Call<BaseRespose<List<TTF>>> getTTF(@QueryMap HashMap<String, Object> params);

    @POST("Robot/text")
    Call<BaseRespose<List<TextBubble>>> getTextBubble(@QueryMap HashMap<String, Object> params);


    @POST("Robot/theme")
    Call<BaseRespose<List<Theme>>> getTheme(@QueryMap HashMap<String, Object> params);

    @POST("Robot/get_theme")
    Call<BaseRespose<Theme>> getThemeById(@QueryMap HashMap<String, Object> params);

    @POST("Robot/sticky")
    Call<BaseRespose<List<Sticky>>> getSticky(@QueryMap HashMap<String, Object> params);

    @POST("Robot/get_sticky")
    Call<BaseRespose<List<Sticky>>> getStickyById(@QueryMap HashMap<String, Object> params);

    @POST("Robot/emoticon")
    Call<BaseRespose<List<EmotionGroup>>> getEmotion(@QueryMap HashMap<String, Object> params);

}
